home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-04 / 422mods.zip / TANIS004.422 < prev    next >
Text File  |  1993-03-07  |  5KB  |  155 lines

  1. Tanis004.mod, old logoff matrix i made, but now, NO ERRORS!
  2. Pull #783 @17310
  3. Wednesday, March 3, 1993  11:24 pm
  4. ┌────────────────────────────────────────────────────────────────────────────┐
  5. │ Mod Name:    :  TANIS004.MOD        Author :  Tanis Half-Elven 1@17315     │
  6. │ Difficulty   :  Easy <Block Read>   Date   :  3/3/93                       │
  7. │ Files Modded :  BBSUTL.C, FCNS.H, BBS.C.                                   │
  8. │ WWIV Version :  4.22                                                       │
  9. │ Description  :  A log off matrix. With lots of functions.                  │
  10. └────────────────────────────────────────────────────────────────────────────┘
  11.   I got this idea from some wierd bbs i had never seen before. I liked the 
  12. letter log off matrix, and decided to make one. Well i used part <very little>
  13. of code from Master Dragon's (1@5801 WWIVNET) Last Chance menu for 4.12. he 
  14. used #'s instead of letters, logged you off after you made a choice, and mine 
  15. returns you to the logoff matrix instead of the bbs.
  16. -*-*-*  Thanx to Galen Pathwarden <again> for help with the endit      *-*-*-
  17. -*-*-*  statements.                                                    *-*-*-
  18.   Aslo in this mod, there are two neat things. One is the account self 
  19. deletetion mod by Fletcher Christian (1@17305 WWIVNET) for 4.12. In that mod
  20. i stuck a line that will print who deleted them selves in the sysoplog, just
  21. so you will know who has been on.
  22.   Ok now on with the mod.
  23.  
  24. Step 1: BACK UP YOUR SOURCE!!!!!. This is very important, and i am not 
  25.     responsible to what happens.
  26.  
  27. Step 2: Open BBSUTL.C.
  28.  
  29. Step 3: Block read void lastmenu(void) at the top.
  30.  
  31. void lastmenu(void)
  32. {
  33.   char ch, s1[80], *s;
  34.   int endit=0;
  35.  
  36.   topscreen();
  37.   do {
  38.   outchr(12);
  39.   printfile ("LASTMENU");
  40.   prt(2,"Which (C,F,E,L,Q,?) : ");
  41.   ch=onek("CFEL?Q");
  42.   switch(ch) {
  43.     case 'C':
  44.       helpl=3;
  45.       reqchat();
  46.       break;
  47.     case 'F':
  48.       strcpy(irt,get_stringx(1,14));
  49.       irt_name[0]=0;
  50.       grab_quotes(NULL, NULL);
  51.       email(1,0,0,0);
  52.       break;
  53.     case 'E':
  54.       send_email();
  55.       break;
  56.     case 'L':
  57.       nl();
  58.       nl();
  59.       prt(5,get_string(28));
  60.       helpl=12;
  61.     if (yn()) {
  62.       outchr(12);
  63.       npr("7You have spent %s minutes of your life here.",ctim(timer()-timeon));
  64.       nl();
  65.    /*   npr("7You have 2%d gold 7left.",(int)thisuser.gold); */
  66.    /*   nl();  */ /* Use this part only if you have the gold mod in*/
  67.       if (thisuser.logons==1) {
  68.     printfile("ACCOUNT");
  69.     prt(2,"Would you like to keep your account here? ");
  70.     if (yn()) {
  71.       printfile("LOGOFF");
  72.       hangup=1;
  73.       endit=1;
  74.     } else {
  75.       s[0]=0;
  76.       sprintf(s,"6*** 1%s 7Deleted himself!!!",thisuser.name);
  77.       nl();
  78.       sysoplog(s);
  79.       hangup=1;
  80.       endit=1;
  81.       dtr(0);
  82.       deluser(usernum);
  83.       checkhangup();
  84.     }
  85.       }
  86.       printfile("LOGOFF");
  87.       nl();
  88.       hangup=1;
  89.       endit=1;
  90.       }
  91.       break;
  92.     case '?':
  93.       break;
  94.     case 'Q':
  95.       endit=1;
  96.       break;
  97.     }
  98.   } while ((!endit) && (!hangup)); return;
  99. }
  100.  
  101. Step 4: Save & Close BBSUTL.C
  102.  
  103. Step 5: Open FCNS.H
  104.  
  105. Step 6: Search for bbsutl.c, and stick in the extra line.
  106.  
  107. /* File: bbsutl.c */
  108.  
  109. void lastmenu(void);                                    /* Add - Me */
  110. void far *malloca(unsigned long nbytes);
  111.  
  112. Step 7: Close & Save FCNS.H.
  113.  
  114. Step 8: Open BBS.C
  115.  
  116. Step 9: Search for case 'O':, and delete it. then stick this in it's place.
  117.  
  118.       case 'O':
  119.     lastmenu();
  120.     break;
  121.  
  122. Step 10: Search again, and do the same thing.
  123.  
  124. Step 11: Close and Save BBS.C.
  125.  
  126. Step 12: Quit and Recompile!
  127.  
  128.   Easy huh? Well if you want to stick and of your own cases, copy the case
  129. statements up there, substitue your own letter, stick  the endit statement
  130. and break; at the end. Also stick the letter in ch=onek(...);. And finally
  131. edit your own lastmenu.msg and .ans. oh here at the bottom are lastmenu and
  132. account.msg. If you have any questions, comments or problems with this mod, I
  133. can be reached at 1@17315 or via the WWIVLink Mod Discussion sub. Cya.
  134.                    7Tanis
  135.                    5The Half-Elven
  136. Lastmenu.Msg
  137.                <YOUR BBS NAME HERE> Log off matrix
  138. +-----------------------------------Commands----------------------------------+
  139. |<C> Try to Chat with <YOUR NAME HERE> <Say goodbye>                          |
  140. |<F> Leave Feedback to the Management <Complain again>                        |
  141. |<E> Send E-Mail to another user <Send a letter to a friend>                  |
  142. |<L> Logoff and see the pretty ansi <Return to the REAL world>                |
  143. |<?> Redisplay this menu and the promt <I can't read!>                        |
  144. |<Q> Quit logging off and return to <YOUR BBS NAME HERE> <Why leave?>         |
  145. +-----------------------------------------------------------------------------+
  146.  
  147. Account.Msg
  148.   Thanks for call us here at <YOUR BBS NAME HERE>. Now that you have had a
  149. chance tolook around and get a feel fo the board, I'd appreciate you letting
  150. me know ifyou intend to call again. If you answer no, it will in no way prevent
  151. you from calling again and acessing the system.
  152.                   <YOUR NAME HERE>
  153.  
  154. Till next mod, CYA!
  155.